package com.zheng.upms.rpc.api;

import com.zheng.common.base.BaseService;
import com.zheng.upms.dao.model.UpmsScheduleJob;
import com.zheng.upms.dao.model.UpmsScheduleJobExample;

/**
* UpmsScheduleJobService接口
* Created by shuzheng on 2019/8/5.
*/
public interface UpmsScheduleJobService extends BaseService<UpmsScheduleJob, UpmsScheduleJobExample> {

    /**
     * 初始化定时任务
     */
    void initScheduleJob() throws Exception;

    int saveScheduleJob(UpmsScheduleJob scheduleJob) throws Exception;

    int updateScheduleJob(UpmsScheduleJob scheduleJob) throws Exception;

    int deleteScheduleJob(String ids) throws Exception;

    void pauseJob(Long jobId) throws Exception;

    void resumeJob(Long jobId) throws Exception;

    void runOnce(Long jobId) throws Exception;
}